<?php

/**
 * EditComment form.
 *
 * @package    cpfaizenay
 * @subpackage form
 * @author     Your name here
 * @version    SVN: $Id: sfDoctrineFormTemplate.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class EditCommentForm extends BaseCommentForm
{
  public function configure() {
      
      $this->widgetSchema['body'] = new sfWidgetFormTextareaTinyMCE(array(
              'width'  => 473,
              'height' => 114,
              'config' => 'theme : "advanced",
                           mode : "textareas",
                           language : "fr",
                           relative_urls : false,
                           cleanup : true,
                           plugins : "paste,table,advimage,advlink,emotions,preview,searchreplace,print,contextmenu,fullscreen",
                           theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,zoom,forecolor,backcolor,|,link,unlink,image,|,emotions,fullscreen",
                           theme_advanced_buttons2 : "",
                           theme_advanced_buttons3 : "",
                           theme_advanced_disable : "help",
                           theme_advanced_toolbar_location : "top",
                           theme_advanced_toolbar_align : "left",
                           theme_advanced_resizing : true,
                           theme_advanced_resize_horizontal : false,
                           theme_advanced_resizing_use_cookie : false,
                           indentation : "10px",
                           skin : "o2k7",
                           skin_variant : "black",
                           width : "100%",
                           height : "100"'
        ));

      $this->setValidator('body', new sfValidatorString(array('required' => true)));

      $this->widgetSchema->setNameFormat('edit_comment[%s]');
      unset($this['record_model'], $this['record_id'], $this['record_slug'], $this['reply'], $this['user_id'], $this['id'], $this['user_name'], $this['reply_author'],
            $this['author_name'], $this['author_email'], $this['author_website'], $this['reply_body'], $this['edition_reason'], $this['is_delete'], $this['created_at'], $this['updated_at']);
  }
}